load("@npm//@bazel/concatjs:index.bzl", "ts_library")

package(default_visibility = ["//visibility:public"])

ts_library(
    name = "map-size-tracking",
    srcs = glob(["**/*.ts"]),
    # A tsconfig needs to be specified as otherwise `ts_library` will look for the config
    # in `//:package.json` and this breaks when the BUILD file is copied to `@npm//`.
    tsconfig = "@npm//@angular/build-tooling:tsconfig.json",
    deps = [
        "@npm//@bazel/runfiles",
        "@npm//@types/node",
        "@npm//source-map",
    ],
)

# Make source files available for distribution via pkg_npm
filegroup(
    name = "files",
    srcs = glob(["*"]),
)
